package com.hhh.tools.model

import retrofit2.Retrofit
import retrofit2.converter.gson.GsonConverterFactory


object Network {

    //文档地址：https://docs.apipost.cn/preview/1a28e17fa3c8f473/16838456ae6dc5c7
    //mock 数据请求 url
    private const val baseUrl = "https://jss.test.zjjushuashua.com/api/"

    private val retrofit = Retrofit.Builder()
        .baseUrl(baseUrl)
        .addConverterFactory(GsonConverterFactory.create()).build()

    fun <T> createService(clazz: Class<T>): T {
        return retrofit.create(clazz)
    }
}